<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <link rel="stylesheet" href="style.css">
</head>

<body>
    <div id="app"></div>
    <!-- hash
    <a href="#1"><span>to page 1</span></a>
    <a href="#2"><span>to page 2</span></a>
    <a href="#3"><span>to page 3</span></a>
    <a href="#4"><span>to page 4</span></a>
    <hr>
    history -->
    <a class="link" href="/1"><span>to page 1</span></a>
    <a class="link" href="/2"><span>to page 2</span></a>
    <a class="link" href="/3"><span>to page 3</span></a>
    <a class="link" href="/4"><span>to page 4</span></a>

    <div id="div1" style="display: none;">1</div>
    <div id="div2" style="display: none;">2</div>
    <div id="div3" style="display: none;">3</div>
    <div id="div4" style="display: none;">4</div>
    <div id="div404" style="display: none;">404页面，你要的内容不存在</div>

    <!-- <script src="router-hash.js"></script> -->
    <!-- <script src="router-history.js"></script> -->
    <script src="router-memory.js"></script>

</body>

</html>